﻿using System;
using System.Collections.Generic;
using System.Text;
using System.Windows.Data;
using System.ComponentModel;
using System.Windows;
using SilverlightDebateViewModel.SilverlightDebateWS;
using System.Windows.Input;
using System.Collections.ObjectModel;

namespace SilverlightDebateView.Classes
{
    public class NewStatementVM : INotifyPropertyChanged, IPopup
    {
        public NewStatementVM()
        {
            ObjStatement = new SilverlightDebateViewModel.SilverlightDebateWS.Statement();
        }

        #region Properties

        private SilverlightDebateViewModel.SilverlightDebateWS.Statement _ObjStatement;
        public SilverlightDebateViewModel.SilverlightDebateWS.Statement ObjStatement
        {
            get { return _ObjStatement; }
            set
            {
                if (_ObjStatement == value)
                {
                    return;
                }
                _ObjStatement = value;
                this.NotifyPropertyChanged("ObjStatement");
            }
        }

        #region Category
        private Category _Category;
        public Category Category
        {
            get { return this._Category; }
            set
            {
                if (this._Category != value)
                {
                    this._Category = value;
                    
                    this.NotifyPropertyChanged("Category");
                }
            }
        }
        #endregion


        #endregion

        #region INotifyPropertyChanged
        public event PropertyChangedEventHandler PropertyChanged;

        private void NotifyPropertyChanged(String info)
        {
            if (PropertyChanged != null)
            {
                PropertyChanged(this, new PropertyChangedEventArgs(info));
            }
        }
        #endregion

        public bool? DialogResult { get; set; }
    }
}
